Skip to content

refactor(block-kit): inline BlockCompositions calls in actions example - #74

Draft
zimeg wants to merge 1 commit into
mainfrom
inline-blockcompositions-actions
Draft

refactor(block-kit): inline BlockCompositions calls in actions example#74
zimeg wants to merge 1 commit into
mainfrom
inline-blockcompositions-actions

Conversation

@zimeg

@zimeg zimeg commented Sep 1, 2026

Copy link
Copy Markdown
Member

What

Inline the BlockCompositions helper calls in the actions block example (blocks/Actions.java) — drop the import static ...BlockCompositions.plainText; and qualify every call as BlockCompositions.plainText(...).

Why

These examples are surfaced on docs.slack.dev as focused snippets — the docs reference block pins only the exampleNN() body, so the static imports at the top of the file are never shown to the reader. A bare plainText(...) in the surfaced range reads as an unattributed free function.

Qualifying the calls makes each surfaced snippet self-attributing (BlockCompositions.plainText(...)), consistent with how the sibling Blocks.* / BlockElements.* calls already name their class.

Purely cosmetic — no payload or behavior change.

Scope

Just blocks/Actions.java (13 calls now qualified). Kept separate from the composition-object and element example inlining so each is a small, reviewable diff.

Verified

  • mvn spotless:check compileBUILD SUCCESS
  • Diff touches only blocks/Actions.java

🤖 Generated with Claude Code

The actions block example mixed a static import of plainText with
fully-qualified BlockCompositions.plainText calls in the same file. Because
these examples are surfaced in docs.slack.dev as focused snippets (only the
exampleNN() body is shown — the imports are not visible to the reader), a
bare plainText(...) reads as an unattributed free function.

Drop the static import and qualify the remaining calls so every helper in
the surfaced range names its class (BlockCompositions.plainText,
BlockElements.button, Blocks.actions) — self-contained and consistent.

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
@zimeg zimeg added documentation Improvements or additions to documentation update PR only - an update or maintenance is being made to an existing app dependencies Pull requests that update a dependency file java Pull requests that update java code labels Sep 1, 2026
@zimeg zimeg self-assigned this Sep 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file documentation Improvements or additions to documentation java Pull requests that update java code update PR only - an update or maintenance is being made to an existing app

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant